<template>
  <view class="data-source-page">
    <view class="page-header">
      <view class="header-back" @click="goBack">
        <uni-icons type="left" size="20" color="#2c3e50"></uni-icons>
      </view>
      <text class="header-title">数据源设置</text>
    </view>
    
    <view class="page-content">
      <data-source-switcher></data-source-switcher>
    </view>
  </view>
</template>

<script>
import DataSourceSwitcher from '@/components/DataSourceSwitcher.vue'

export default {
  name: 'DataSourcePage',
  components: {
    DataSourceSwitcher
  },
  methods: {
    goBack() {
      uni.navigateBack()
    }
  }
}
</script>

<style lang="scss" scoped>
.data-source-page {
  min-height: 100vh;
  background-color: #f8f9fa;
}

.page-header {
  position: sticky;
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  padding: 20rpx 30rpx;
  background-color: #ffffff;
  box-shadow: 0 2rpx 10rpx rgba(0, 0, 0, 0.05);
}

.header-back {
  width: 60rpx;
  height: 60rpx;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 20rpx;
}

.header-title {
  font-size: 36rpx;
  font-weight: 600;
  color: #2c3e50;
}

.page-content {
  padding-bottom: 40rpx;
}
</style>